import React from 'react'
import { Link } from 'react-router-dom'

import st from './index.scss'

export default class Home extends React.Component {
  interesting_list = [
    {
      title: 'let num = 020不等于let num = 20',
      link: '/interesting/num-first-0'
    },
    {
      title: '排序的N种方式',
      link: '/interesting/sort'
    }
  ]

  render() {
    return (
      <div>
        <div>本网旨在写一些关于前端有趣的事情和实验</div>
        <div>（样式这种事等有一定积累再说）</div>
        <h1>有趣的事</h1>
        <div className={st['list']}>
          {this.interesting_list.map((obj, idx) => {
            return (
              <Link to={obj.link} key={idx}>
                {idx + 1}：{obj.title}
              </Link>
            )
          })}
        </div>
      </div>
    )
  }
}
